home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Gigarom 1
/
Gigarom Macintosh Archives (Quantum Leap)(CDRM1080320)(1993).iso
/
FILES
/
HYP
/
C-D
/
DeveloperStax.cpt
/
Developer Stack 1.1
/
card_4015.txt
< prev
next >
Wrap
Text File
|
1989-02-26
|
2KB
|
97 lines
-- card: 4015 from stack: in.1
-- bmap block id: 0
-- flags: 4000
-- background id: 3837
-- name: FileName
----- HyperTalk script -----
on closecard
hide message window
end closecard
-- part 10 (button)
-- low flags: 00
-- high flags: A004
-- rect: left=223 top=245 right=293 bottom=283
-- title width / last selected line: 0
-- icon id / first selected line: 27056 / 27056
-- text alignment: 1
-- font id: 0
-- text size: 12
-- style flags: 0
-- line height: 16
-- part name: Try it
----- HyperTalk script -----
on mouseUp
if the optionkey is down then pass mouseup
put "Just select a file & it will return the full pathname"
put filename()
end mouseUp
-- part 11 (button)
-- low flags: 00
-- high flags: A003
-- rect: left=82 top=302 right=324 bottom=182
-- title width / last selected line: 0
-- icon id / first selected line: 0 / 0
-- text alignment: 1
-- font id: 0
-- text size: 12
-- style flags: 0
-- line height: 16
-- part name: Install
----- HyperTalk script -----
on mouseUp
if the optionkey is down then pass mouseup
put installres(XFCN,FileName) into it
if it is empty then play oops
else answer it
end mouseUp
-- part contents for background part 6
----- text -----
This allows your HyperTalk scripts to request a filename via a Standard File Package dialog box.
Thanks to:
Steve Maller, Apple Computer.
AppleLink: maller1 • Delphi: stevemaller • MCI Mail: smaller
-- part contents for background part 5
----- text -----
FileName
-- part contents for background part 10
----- text -----
1
-- part contents for background part 7
----- text -----
Syntax:
FileName()
shows all files, or
FileName("TYPE")
where "TYPE" is the type of the file you want to open.
For example:
FileName("APPL") will show only applications
FileName("STAK") will show only stacks.
FileName("TEXT") will show only text documents.